package com.lk.mi.service.impl;

import com.lk.mi.entity.User;
import com.lk.mi.mapper.userMapper;
import com.lk.mi.service.userService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


@Service
public class userServiceImpl implements userService {

    @Autowired
    private userMapper userMapper;

    @Override
    public User login(String username, String password) {
        User user = userMapper.login(username, password);
        return user;
    }

    @Override
    public Integer register(String username, String password) {
        Integer row = userMapper.register(username, password);
        return row;
    }

    @Override
    public Integer destroy(Integer id) {
        Integer row = userMapper.destroy(id);
        return row;
    }


}
